iconhelper: Use the screen's icon theme
authorBenjamin Otte <otte@redhat.com>
Thu, 12 Mar 2015 00:14:06 +0000 (01:14 +0100)
committerBenjamin Otte <otte@redhat.com>
Thu, 12 Mar 2015 00:15:38 +0000 (01:15 +0100)
... and not the default one.

gtk/gtkiconhelper.c

index 1f598b1c0c1e5f0ae6b25e36037bfbaa51130905..08c9838b6a856b6b3a58b2ae431db74025793b09 100644 (file)
@@ -288,7 +288,7 @@ ensure_pixbuf_for_gicon (GtkIconHelper *self,
   if (self->priv->rendered_pixbuf)
     return;
 
-  icon_theme = gtk_icon_theme_get_default ();
+  icon_theme = gtk_icon_theme_get_for_screen (gtk_style_context_get_screen (context));
   flags = get_icon_lookup_flags (self, context);
 
   ensure_icon_size (self, context, &width, &height);
@@ -707,7 +707,7 @@ ensure_surface_for_gicon (GtkIconHelper   *self,
   if (!check_invalidate_surface (self, context))
     return;
 
-  icon_theme = gtk_icon_theme_get_default ();
+  icon_theme = gtk_icon_theme_get_for_screen (gtk_style_context_get_screen (context));
   flags = get_icon_lookup_flags (self, context);
 
   ensure_icon_size (self, context, &width, &height);